@import '~@/scss/GlobalVariables';

%overall-padding {
  padding: 10px;
}

.sign-transaction-container {
  display: flex;
  flex-direction: column;
  height: 478px;
  position: relative;

  .sign-transaction-header {
    @extend %overall-padding;

    padding-bottom: 0;

    p {
      font-size: 20px;
      font-weight: bold;
      margin: 0;
    }
  }

  .sign-transaction-addresses {
    @extend %overall-padding;

    align-items: center;
    display: flex;
    flex-direction: column;

    img {
      padding: 10px 0;
    }
  }

  .details-container {
    border-bottom: 1px solid $dark-grey-11;
    border-top: 1px solid $dark-grey-11;
    margin: 0 10px;

    &.add-margin {
      margin-bottom: 10px;
    }

    .details-header-container {
      @extend %overall-padding;

      align-items: center;
      display: flex;
      justify-content: space-between;

      p {
        font-weight: bold;
        margin: 0;
      }
    }

    .detail-item {
      display: flex;
      justify-content: space-between;
      padding: 10px 0;

      .title {
        color: $dark-grey-11;
      }

      .content {
        color: $dark-blue-12;
        padding-left: 10px;
        word-break: break-word;
      }
    }
  }

  .continue-button {
    background-color: $mew-green;
    border: 1px solid $mew-green;
    color: $white;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    user-select: none;
    display: inline-block;
    text-align: center;
    padding: 21px 55px;
    width: 100%;

    &.details-closed {
      bottom: 0;
      position: absolute;
    }
  }
}

.shown {
  transition: max-height 0.5s ease-out;
  padding: 0 10px 10px;
}

.hide-box {
  display: none;
  height: 0;
  transition: max-height 0.5s ease-out;
}

.sliding-switch-white {
  height: 27px;
  position: relative;

  .switch {
    display: inline-block;
    height: 28px;
    position: relative;
    width: 52px;

    // Hide default HTML checkbox
    input {
      display: none;
    }
  }

  // The slider
  .slider {
    background-color: $css-toggle-button--slider-background-color;
    bottom: 0;
    cursor: pointer;
    left: 0;
    position: absolute;
    right: 0;
    top: 0;
    transition: 0.4s;

    &::before {
      background-color: $text-white;
      bottom: 3px;
      content: '';
      height: 22px;
      left: 3px;
      padding: 1px 7px;
      position: absolute;
      transition: 0.4s;
      width: 23px;
    }

    // Rounded sliders
    &.round {
      border-radius: 34px;
    }

    &.round::before {
      border-radius: 100%;
    }
  }

  input:checked + .slider {
    background-color: $css-toggle-button--slider--active--background-color;
  }

  input:focus + .slider {
    box-shadow: 0 0 1px $css-toggle-button--slider--active--background-color;
  }

  input:checked + .slider::before {
    transform: translateX(23px);
  }
}
